
var Router  = require('koa-router')();
var fs =require('fs');
Router.post('/pdf',(cxt)=>{
	var data = cxt.request.body;
	// fs.writeFileSync('test.txt','addd',(err)=>{

	// 	// fs.writeSync('test.txt','aadasd')
	// })
	var stats  = fs.exists('test.txt')
	console.log(stats,'isFile')
	// fs.unlinkSync('test.txt')
	console.log(data,'data')
	cxt.body ={
		msg:'pl'
	}
})


module.exports = Router